{
 "metadata": {
  "name": ""
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "markdown",
     "metadata": {},
     "source": [
      "Se inicializa a simula\u00e7\u00e3o para um grupo de particulas numa dimens\u00e3o (1D). Como primeiro caso N = 9"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "%run Gas.py"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 1
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gas_old = Gas(9)\n",
      "gas_new = Gas(9)\n",
      "gas_old.iniVel(1)\n",
      "gas_new.iniVel(1)\n",
      "gas_ini = copy.deepcopy(gas_old)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 2
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gas_ini.vec_v"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 3,
       "text": [
        "array([[ 1.3315865 ,  0.        ,  0.        ],\n",
        "       [ 0.71527897,  0.        ,  0.        ],\n",
        "       [-1.54540029,  0.        ,  0.        ],\n",
        "       [-0.00838385,  0.        ,  0.        ],\n",
        "       [ 0.62133597,  0.        ,  0.        ],\n",
        "       [-0.72008556,  0.        ,  0.        ],\n",
        "       [ 0.26551159,  0.        ,  0.        ],\n",
        "       [ 0.10854853,  0.        ,  0.        ],\n",
        "       [ 0.00429143,  0.        ,  0.        ]])"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gas_ini.calculateEkin_n()\n",
      "gas_ini.Ekin_n.sum()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 4,
       "text": [
        "2.8299790945754504"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gamma  = 1.0\n",
      "Tleft  = 1.0\n",
      "Tright = 2.0\n",
      "Wrange = 1.0\n",
      "dt = 0.00001\n",
      "total_time =10000000"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 6
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "timeDim = 1000\n",
      "gasTime = GasTime(gas_old,timeDim)\n",
      "taux = total_time/timeDim"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 7
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "######\n",
      "# FIXME: Redundant two lines\n",
      "gas_old.calculateDeltas()\n",
      "gas_old.calculateForces()\n",
      "gas_old.leftHB(gamma, Tleft, Wrange)\n",
      "gas_old.rightHB(gamma, Tright, Wrange)\n",
      "for i in range(total_time):    \n",
      "    \n",
      "    gas_new.stepPosition(gas_old,dt)\n",
      "    gas_new.inBox(gas_old)\n",
      "    \n",
      "    gas_new.calculateDeltas()\n",
      "    gas_new.calculateForces()\n",
      "    gas_old.leftHB(gamma, Tleft, Wrange)\n",
      "    gas_old.rightHB(gamma, Tright, Wrange)\n",
      "    gas_new.stepVelocity(gas_old, dt)\n",
      "    \n",
      "    gas_new.calculateHalfV()\n",
      "    gas_new.calculateEkin_n()\n",
      "    gas_new.calculateEnerDensity()  # h_n\n",
      "    gas_new.calculateFluxDensity()  # j_n\n",
      "    \n",
      "    if i % taux == 0:\n",
      "        gasTime.saveMicroState(gas_new, i, dt)\n",
      "        gasTime.saveState(gas_new, i, dt)\n",
      "    \n",
      "    #save the values for the next step\n",
      "    gas_old = copy.deepcopy(gas_new)\n",
      "    \n",
      "    #plt.plot(range(len(gas_old.Ekin_n)), gas_old.Ekin_n)\n",
      "\n",
      "######\n",
      "gasTime.savetxt(\"TimeEvolution2.dat\")\n",
      "gas_end = copy.deepcopy(gas_new)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 1 2"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 3 4"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 5 6"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 7 8"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 9 10"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 114.64628716479e-06"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " -1.08313386657 -10.0000046463\n",
        "4.64628716479e-06 1.08313386657 -9.99999535371 ***** 0\n",
        " 12"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 13 14"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 15 16"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 17 18"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 19 20"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 21 22"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "8.32574336584e-07 -0.582695968324 -10.0000008326\n",
        "8.32574336584e-07 0.582695968324 -9.99999916743 ***** 0\n",
        " 23"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 24 25"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 26 27"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 28 29"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 30 31"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 32 33"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 34 35"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 36 37"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 38 39"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 40 41"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 42 43"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 44 45"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 46 47"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 48 49"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 50 51"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 52 53"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 54 55"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 56 57"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 58 59"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 60 61"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 62 63"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 64 65"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 66 67"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 68 69"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 70 71"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 72 73"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 74 75"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 76 77"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 78 79"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 80 81"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 82 83"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 84 85"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 86 87"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 88 89"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 90 91"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 92 93"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 94 95"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 96 97"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 98 99"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 100 101"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 102 103"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 104 105"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 106 107"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 108 109"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 110 111"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 112 113"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 114 115"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 116 117"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 118 119"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 120 121"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 122 123"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 124 125"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 126 127"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 128 129"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 130 131"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 132 133"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 134 135"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 136 137"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 138 139"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 140 141"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 142 143"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 144 145"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 146 147"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 148 149"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 150 151"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 152 153"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 154 155"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 156 157"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 158 159"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 160 161"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 162 163"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 164 165"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 166 167"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 168 169"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 170 171"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 172 173"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 174 175"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 176 177"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 178 179"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 180 181"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 182 183"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 184 185"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 186 187"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 188 189"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 190 191"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 192 193"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 194 195"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 196 197"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 198 199"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 200 201"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 202 203"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 204 205"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 206 207"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 208 209"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 210 211"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 212 213"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 214 215"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 216 217"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 218 219"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 220 221"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 222 223"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 224 225"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 226 227"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 228 229"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 230 231"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 232 233"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 234 235"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 236 237"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 238 239"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 240 241"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 242 243"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 244 245"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 246 247"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 248 249"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 250 251"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 252 253"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 254 255"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 256 257"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 258 259"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 260 261"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 262 263"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 264 265"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 266 267"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 268 269"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 270 271"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 272 273"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 274 275"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 276 277"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 278 279"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 280 281"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 282 283"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 284 285"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 286 287"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 288 289"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 290 291"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 292 293"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 294 295"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 296 297"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 298 299"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 300 301"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 302 303"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 304 305"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 306 307"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 308 309"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 310 311"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 312 313"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 314 315"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 316 317"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 318 319"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 320 321"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 322 323"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 324 325"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 326 327"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 328 329"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 330 331"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 332 333"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 334 335"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 336 337"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 338 339"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 340 341"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 342 343"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 344 345"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 346 347"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 348 349"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 350 351"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 352 353"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 354 355"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 356 357"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 358 359"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 360 361"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 362 363"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 364 365"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 366 367"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 368 369"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 370 371"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 372 373"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 374 375"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 376 377"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 378 379"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 380 381"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 382 383"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 384 385"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 386 387"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 388 389"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 390 391"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 392 393"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 394 395"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 396 397"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 398 399"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 400 401"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 402 403"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 404 405"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 406 407"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 408 409"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 410 411"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 412 413"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 414 415"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 416 417"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 418 419"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 420 421"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 422 423"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 424 425"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 426 427"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 428 429"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 430 431"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 432 433"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 434 435"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 436 437"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 438 439"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 440 441"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 442 443"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 444 445"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 446 447"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 448 449"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 450 451"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 452 453"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 454 455"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 456 457"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 458 459"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 460 461"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 462 463"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 464 465"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 466 467"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 468 469"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 470 471"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 472 473"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 474 475"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 476 477"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 478 479"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 480 481"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 482 483"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 4842.29992979506e-06"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " -0.393782862724 -10.0000022999\n",
        "2.29992979506e-06 0.393782862724 -9.99999770007 ***** 0\n",
        " 485"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 486 487"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 488 489"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 490 491"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 492 493"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 494 495"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 496 497"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 498 499"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 500 501"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 502 503"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 504 505"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 506 507"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 508 509"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 510 511"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 512 513"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 514 515"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 516 517"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 518 519"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 520 521"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 522 523"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 524 525"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 526 527"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 528 529"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 530 531"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 532 533"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 534 535"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 536 537"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "2.92805585644e-06 -0.346116517552 -10.0000029281\n",
        "2.92805585644e-06 0.346116517552 -9.99999707194 ***** 0\n",
        " 538"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 539 540"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 541 542"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 543 544"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 545 546"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 547 548"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "9.27630006586e-07 -0.172397450978 -10.0000009276\n",
        "9.27630006586e-07 0.172397450978 -9.99999907237 ***** 0\n",
        " 549"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 550 551"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 552 553"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 554 555"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "1.4898820897e-06 -0.419120362266 -10.0000014899\n",
        "1.4898820897e-06 0.419120362266 -9.99999851012 ***** 0\n",
        " 556"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 557 558"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 559 560"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 561 562"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 563 564"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 565 566"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 567 568"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 569 570"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 571 572"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 573 574"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 575 576"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 577 578"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 579 580"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 581 582"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 583 584"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 585 586"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 587 588"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 589 590"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 591 592"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 593 594"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 595 596"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 597 598"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 599 600"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 601 602"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 603 604"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 605 606"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 607 608"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 609 610"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 611 612"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 613 614"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 615 616"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 617 618"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 619 620"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 621 622"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 623 624"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 625 626"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 627 628"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 629 630"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 631 632"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 633 634"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 635 636"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 637 638"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 639 640"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 641 642"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 643 644"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 645 646"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 647 648"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 649 650"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 651 652"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 653 654"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 655 656"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 657 658"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 659 660"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 661 662"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 663 664"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 665 666"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 667 668"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 669 670"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 671 672"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 673 674"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 675 676"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 677 678"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 679 680"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 681 682"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 683 684"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 685 686"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 687 688"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 689 690"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 691 692"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 693 694"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 695 696"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 697 698"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 699 700"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 701 702"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 703 704"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 705 706"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 707 708"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 709 710"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 711 712"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 713 714"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 715 716"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 717 718"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 719 720"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 721 722"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 723 724"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 725 726"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 727 728"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 729 730"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 731 732"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 733 734"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 735 736"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 737 738"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 739 740"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 741 742"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 743 744"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 745 746"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 747 748"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 749 750"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 751 752"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 753 754"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 755 756"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 757 758"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 759 760"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 761 762"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 763 764"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 765 766"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 767 768"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 769 770"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 771 772"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 773 774"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 775 776"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 777 778"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 779 780"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 781 782"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 783 784"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 785 786"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 787 788"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 789 790"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 791 792"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 793 794"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 795 796"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 797 798"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 799 800"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 801 802"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 803 804"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 805 806"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 807 808"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 809 810"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 811 812"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 813 814"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 815 816"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 817 818"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 819 820"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 821 822"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 823 824"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 825 826"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 827 828"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 829 830"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 831 832"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 833 834"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 835 836"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 837 838"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 839 840"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 841 842"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 843 844"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 845 846"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 847 848"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 849 850"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 851 852"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 853 854"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 855 856"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 857 858"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 859 860"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 861 862"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 863 864"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 865 866"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 867 868"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 869 870"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 871 872"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 873 874"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 875 876"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 877 878"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 879 880"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 881 882"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 883 884"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 885 886"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 887 888"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 889 890"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 891 892"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 893 894"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 895 896"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 897 898"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 899 900"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 901 902"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 903 904"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 905 906"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 907 908"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 909 910"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 911 912"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 913 914"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 915 916"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 917 918"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 919 920"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 921 922"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 923 924"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 925 926"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 927 928"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 929 930"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 931 932"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 933 934"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 935 936"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 937 938"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 939 940"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 941 942"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 943 944"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 945 946"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 947 948"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 949 950"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 951 952"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 953 954"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 955 956"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 957 958"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 959 960"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 961 962"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 963 964"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 965 966"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 967 968"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 969 970"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 971 972"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 973 974"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 975 976"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 977 978"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 979 980"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 981 982"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 983 984"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 985 986"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 987 988"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 989 990"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 991 992"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 993 994"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 995 996"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 997 998"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 999 1000"
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "TimeEvolution2.dat\n"
       ]
      }
     ],
     "prompt_number": 8
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasTime.savetxt(\"TimeEvolutionTl1Tr2.dat\")\n",
      "gas_end.savetxt(\"gas_endTl1Tr2.dat\")"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "TimeEvolutionTl1Tr2.dat\n"
       ]
      }
     ],
     "prompt_number": 9
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "np.savetxt(\"gas_endTl1Tr2.dat\", np.hstack((gas_old.vec_r,gas_old.vec_v)) )"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 11
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {},
     "source": [
      "Plots"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "# Plot total density flux\n",
      "plt.grid()\n",
      "plt.rc('font', size=25)\n",
      "plt.rc('text', usetex=True)\n",
      "plt.plot(gasTime.time,gasTime.fluxDenst.sum(axis=1))\n",
      "plt.xlabel(\"$t$\")\n",
      "plt.ylabel(\"$j_{tot}$\")\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 46
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "# Plot position vs time\n",
      "plt.grid()\n",
      "plt.rc('font', size=30)\n",
      "plt.rc('text', usetex=True)\n",
      "plt.ylabel(\"$x$\")\n",
      "plt.xlabel(\"$t$\")\n",
      "for i in range(gas_old.N):\n",
      "    plt.plot(gasTime.time, gasTime.xt[:,i])\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 41
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "# Plot Figura cores\n",
      "fig, ax = plt.subplots()\n",
      "plt.title(\"$ j_{x_n} $\")\n",
      "plt.ylabel(\"$t$ steps\")\n",
      "plt.xlabel(\"$n$\")\n",
      "#plt.colorbar()\n",
      "#heatmap = ax.pcolor(enerDensTemp, cmap='RdBu')#plt.cm.Blues) #[:,1:gas_old.N-2]\n",
      "heatmap = ax.pcolor(gasTime.fluxDenst[700:], cmap='RdBu')#plt.cm.Blues)\n",
      "fig.colorbar(heatmap)\n",
      "#plt.imshow(enerDensTemp[:,1:gas_old.N-2])\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 38
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "len(gasTime.fluxDenst[500:])"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 34,
       "text": [
        "500"
       ]
      }
     ],
     "prompt_number": 34
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "# Plot Temperature vs position.\n",
      "plt.grid()\n",
      "plt.rc('font', size=30)\n",
      "plt.rc('text', usetex=True)\n",
      "plt.ylabel(\"$T$\")\n",
      "plt.xlabel(\"$n$\")\n",
      "\n",
      "plt.plot(range(gas_old.N),gasTime.Ekin_nt[0])\n",
      "plt.show()\n",
      "#gasTime.Ekin_nt.mean(axis=0)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 25
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasTime.Ekin_nt[2]"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 23,
       "text": [
        "array([ 0.69982439,  0.05440827,  0.74074873,  0.00811523,  0.23940748,\n",
        "        0.2295255 ,  0.00333981,  0.01712926,  0.09998419])"
       ]
      }
     ],
     "prompt_number": 23
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gas2_old = Gas(9)\n",
      "gas2_new = Gas(9)\n",
      "gas2_old.iniVel(1)\n",
      "gas2_new.iniVel(1)\n",
      "gas2_ini = copy.deepcopy(gas2_old)\n",
      "gamma  = 1.0\n",
      "Tleft  = 1.0\n",
      "Tright = 4.0\n",
      "Wrange = 1.0\n",
      "dt = 0.00001\n",
      "total_time =10000000\n",
      "\n",
      "timeDim = 1000\n",
      "gas2Time = GasTime(gas_old,timeDim)\n",
      "taux = total_time/timeDim\n",
      "\n",
      "######\n",
      "# FIXME: Redundant two lines\n",
      "gas2_old.calculateDeltas()\n",
      "gas2_old.calculateForces()\n",
      "gas2_old.leftHB(gamma, Tleft, Wrange)\n",
      "gas2_old.rightHB(gamma, Tright, Wrange)\n",
      "for i in range(total_time):    \n",
      "    \n",
      "    gas2_new.stepPosition(gas2_old,dt)\n",
      "    gas2_new.inBox(gas2_old)\n",
      "    \n",
      "    gas2_new.calculateDeltas()\n",
      "    gas2_new.calculateForces()\n",
      "    gas2_old.leftHB(gamma, Tleft, Wrange)\n",
      "    gas2_old.rightHB(gamma, Tright, Wrange)\n",
      "    gas2_new.stepVelocity(gas2_old, dt)\n",
      "    \n",
      "    gas2_new.calculateHalfV()\n",
      "    gas2_new.calculateEkin_n()\n",
      "    gas2_new.calculateEnerDensity()  # h_n\n",
      "    gas2_new.calculateFluxDensity()  # j_n\n",
      "    \n",
      "    if i % taux == 0:\n",
      "        gas2Time.saveMicroState(gas2_new, i, dt)\n",
      "        gas2Time.saveState(gas2_new, i, dt)\n",
      "    \n",
      "    #save the values for the next step\n",
      "    gas2_old = copy.deepcopy(gas2_new)\n",
      "    \n",
      "    #plt.plot(range(len(gas2_old.Ekin_n)), gas2_old.Ekin_n)\n",
      "\n",
      "######\n",
      "gas2Time.savetxt(\"TimeEvolution2.dat\")\n",
      "gas2_end = copy.deepcopy(gas2_new)\n",
      "gas2_end.savetxt(\"gas2_endTl1Tr4.dat\")\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 1 2"
       ]
      },
      {
       "ename": "KeyboardInterrupt",
       "evalue": "",
       "output_type": "pyerr",
       "traceback": [
        "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m\n\u001b[0;31mKeyboardInterrupt\u001b[0m                         Traceback (most recent call last)",
        "\u001b[0;32m<ipython-input-12-9a6b931d1510>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m()\u001b[0m\n\u001b[1;32m     35\u001b[0m     \u001b[0mgas2_new\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcalculateEkin_n\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m     36\u001b[0m     \u001b[0mgas2_new\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcalculateEnerDensity\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m  \u001b[0;31m# h_n\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m---> 37\u001b[0;31m     \u001b[0mgas2_new\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mcalculateFluxDensity\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m  \u001b[0;31m# j_n\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m     38\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m     39\u001b[0m     \u001b[0;32mif\u001b[0m \u001b[0mi\u001b[0m \u001b[0;34m%\u001b[0m \u001b[0mtaux\u001b[0m \u001b[0;34m==\u001b[0m \u001b[0;36m0\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
        "\u001b[0;32m/home/alfaceor/Projects/ceor-phd/GasHeatBath/Gas.py\u001b[0m in \u001b[0;36mcalculateFluxDensity\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m    221\u001b[0m           \u001b[0maux\u001b[0m  \u001b[0;34m=\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mFx\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mj\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_v\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m]\u001b[0m \u001b[0;34m+\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_v\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mj\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    222\u001b[0m           \u001b[0maux\u001b[0m \u001b[0;34m+=\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mFy\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mj\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_v\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;36m1\u001b[0m\u001b[0;34m]\u001b[0m \u001b[0;34m+\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_v\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mj\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;36m1\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 223\u001b[0;31m           \u001b[0maux\u001b[0m \u001b[0;34m+=\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mFz\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mj\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_v\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m]\u001b[0m \u001b[0;34m+\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_v\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mj\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;36m2\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    224\u001b[0m           \u001b[0maux_vec\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0;34m(\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_r\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m \u001b[0;34m-\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_r\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mj\u001b[0m\u001b[0;34m]\u001b[0m \u001b[0;34m)\u001b[0m \u001b[0;34m*\u001b[0m \u001b[0maux\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    225\u001b[0m       \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mfluxDensity\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0menerDensity\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvec_v\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mi\u001b[0m\u001b[0;34m]\u001b[0m \u001b[0;34m+\u001b[0m \u001b[0;36m0.5\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0maux_vec\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
        "\u001b[0;31mKeyboardInterrupt\u001b[0m: "
       ]
      },
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        " 3"
       ]
      }
     ],
     "prompt_number": 12
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasTime.Ekin_nt.mean(axis=0)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 84,
       "text": [
        "array([ 0.00238017,  0.00138054,  0.00244663,  0.0024977 ,  0.00291151,\n",
        "        0.00196169,  0.00241023,  0.00200979,  0.00158597])"
       ]
      }
     ],
     "prompt_number": 84
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "plt.plot(range(9), gasTime.enerDenst[500:1200].mean(axis=0))\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 89
    },
    {
     "cell_type": "markdown",
     "metadata": {},
     "source": [
      "Preciso salvar o estado do gas e para isso preciso olhar o codigo anterior"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "len(gasTime.enerDenst[:500,0:])"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 65,
       "text": [
        "500"
       ]
      }
     ],
     "prompt_number": 65
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "np.savetxt(\"UltimoEstado.dat\",np.hstack((gas_end.vec_r,gas_end.vec_v)))"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 96
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasTime.enerDenst[500,:].std()\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 56,
       "text": [
        "0.019324180126605396"
       ]
      }
     ],
     "prompt_number": 56
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "print len(gasTime.time), len(gasTime.enerDenst), len(gasTime.fluxDenst)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "20 20 20\n"
       ]
      }
     ],
     "prompt_number": 13
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "rrr=np.hstack((gasTime.time.transpose(),gasTime.enerDenst,gasTime.enerDenst))\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "ename": "ValueError",
       "evalue": "all the input arrays must have same number of dimensions",
       "output_type": "pyerr",
       "traceback": [
        "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m\n\u001b[0;31mValueError\u001b[0m                                Traceback (most recent call last)",
        "\u001b[0;32m<ipython-input-19-1cd2d6316761>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m()\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mrrr\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mnp\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mhstack\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mgasTime\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mtime\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mtranspose\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0mgasTime\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0menerDenst\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0mgasTime\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0menerDenst\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
        "\u001b[0;32m/usr/lib/python2.7/dist-packages/numpy/core/shape_base.pyc\u001b[0m in \u001b[0;36mhstack\u001b[0;34m(tup)\u001b[0m\n\u001b[1;32m    273\u001b[0m     \u001b[0;31m# As a special case, dimension 0 of 1-dimensional arrays is \"horizontal\"\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    274\u001b[0m     \u001b[0;32mif\u001b[0m \u001b[0marrs\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mndim\u001b[0m \u001b[0;34m==\u001b[0m \u001b[0;36m1\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 275\u001b[0;31m         \u001b[0;32mreturn\u001b[0m \u001b[0m_nx\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mconcatenate\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0marrs\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0;36m0\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    276\u001b[0m     \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    277\u001b[0m         \u001b[0;32mreturn\u001b[0m \u001b[0m_nx\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mconcatenate\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0marrs\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0;36m1\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
        "\u001b[0;31mValueError\u001b[0m: all the input arrays must have same number of dimensions"
       ]
      }
     ],
     "prompt_number": 19
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasTime.fluxDenst[0].sum()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 7,
       "text": [
        "0.0"
       ]
      }
     ],
     "prompt_number": 7
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "plt.grid()\n",
      "plt.rc('font', size=25)\n",
      "plt.rc('text', usetex=True)\n",
      "plt.plot(gasTime.time,gasTime.fluxDenst.sum(axis=1))\n",
      "plt.xlabel(\"$t$\")\n",
      "plt.ylabel(\"$j_{tot}$\")\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 76
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "plt.grid()\n",
      "plt.rc('font', size=25)\n",
      "plt.rc('text', usetex=True)\n",
      "plt.plot(gasTime.time,gasTime.enerDenst.sum(axis=1))\n",
      "plt.xlabel(\"$t$\")\n",
      "plt.ylabel(\"$E_{tot}$\")\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 77
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "fig, ax = plt.subplots()\n",
      "plt.title(\"$ j_{x_n} $\")\n",
      "plt.ylabel(\"$t$ steps\")\n",
      "plt.xlabel(\"$n$\")\n",
      "#plt.colorbar()\n",
      "#heatmap = ax.pcolor(enerDensTemp, cmap='RdBu')#plt.cm.Blues) #[:,1:gas_old.N-2]\n",
      "heatmap = ax.pcolor(gasTime.fluxDenst, cmap='RdBu')#plt.cm.Blues)\n",
      "fig.colorbar(heatmap)\n",
      "#plt.imshow(enerDensTemp[:,1:gas_old.N-2])\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 40
    },
    {
     "cell_type": "markdown",
     "metadata": {},
     "source": [
      "Grafica das posi\u00e7\u00f5es das part\u00edculas"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "plt.grid()\n",
      "plt.rc('font', size=30)\n",
      "plt.rc('text', usetex=True)\n",
      "plt.ylabel(\"$x$\")\n",
      "plt.xlabel(\"$t$\")\n",
      "for i in range(gas_old.N):\n",
      "    plt.plot(gasTime.time, gasTime.xt[:,i])\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 78
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "plt.grid()\n",
      "plt.rc('font', size=30)\n",
      "plt.rc('text', usetex=True)\n",
      "plt.ylabel(\"$x$\")\n",
      "plt.xlabel(\"$t$\")\n",
      "plt.plot(gasTime.time, gasTime.xt[:,8],'o')\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 39
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gas_ini.plot()\n",
      "gas_end.plot()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 27
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gas_ini.calculateDeltas()\n",
      "gas_ini.calculateHalfV()\n",
      "gas_ini.calculateEkin_n()\n",
      "gas_ini.calculateEnerDensity()\n",
      "gas_ini.calculateFluxDensity()\n",
      "print gas_ini.fluxDensity.sum(), gas_ini.enerDensity.sum()\n",
      "print gas_end.fluxDensity.sum(), gas_end.enerDensity.sum()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "-0.00401938256292 0.139652490695\n",
        "-0.0857579603098 0.139652490798\n"
       ]
      }
     ],
     "prompt_number": 56
    },
    {
     "cell_type": "markdown",
     "metadata": {},
     "source": [
      "A densidade total de energia esta se conservando. Mas o fluxo deveria ter sido zero "
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "fluxDensTemp.sum(axis)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 63,
       "text": [
        "0.054938355226009573"
       ]
      }
     ],
     "prompt_number": 63
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "plt.plot(time,fluxDensTemp)\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 57
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "len(enerDensTemp)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 75,
       "text": [
        "100000"
       ]
      }
     ],
     "prompt_number": 75
    },
    {
     "cell_type": "markdown",
     "metadata": {},
     "source": [
      "Pode-se notar que a energia n\u00e3o esta sendo conservada o qual deveria ter acontecido para este caso. Por tanto vamos denovo passo a passo"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "%run Gas.py\n",
      "gasIni=Gas(9)\n",
      "gasAux=Gas(9)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 47
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.vec_r"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 48,
       "text": [
        "array([[-4. , -0.5,  0. ],\n",
        "       [-3. , -0.5,  0. ],\n",
        "       [-2. , -0.5,  0. ],\n",
        "       [-1. , -0.5,  0. ],\n",
        "       [ 0. , -0.5,  0. ],\n",
        "       [ 1. , -0.5,  0. ],\n",
        "       [ 2. , -0.5,  0. ],\n",
        "       [ 3. , -0.5,  0. ],\n",
        "       [ 4. , -0.5,  0. ]])"
       ]
      }
     ],
     "prompt_number": 48
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.calculateDeltas()\n",
      "gasIni.deltaX"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 49,
       "text": [
        "array([[ 0.,  1.,  2.,  3.,  4.,  5.,  6.,  7.,  8.],\n",
        "       [-1.,  0.,  1.,  2.,  3.,  4.,  5.,  6.,  7.],\n",
        "       [-2., -1.,  0.,  1.,  2.,  3.,  4.,  5.,  6.],\n",
        "       [-3., -2., -1.,  0.,  1.,  2.,  3.,  4.,  5.],\n",
        "       [-4., -3., -2., -1.,  0.,  1.,  2.,  3.,  4.],\n",
        "       [-5., -4., -3., -2., -1.,  0.,  1.,  2.,  3.],\n",
        "       [-6., -5., -4., -3., -2., -1.,  0.,  1.,  2.],\n",
        "       [-7., -6., -5., -4., -3., -2., -1.,  0.,  1.],\n",
        "       [-8., -7., -6., -5., -4., -3., -2., -1.,  0.]])"
       ]
      }
     ],
     "prompt_number": 49
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.calculateForces()\n",
      "gasIni.Fx[7].sum()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 71,
       "text": [
        "0.015044104303775896"
       ]
      }
     ],
     "prompt_number": 71
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.force[7]"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 72,
       "text": [
        "array([ 0.0150441,  0.       ,  0.       ])"
       ]
      }
     ],
     "prompt_number": 72
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.rc"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 33,
       "text": [
        "2.5"
       ]
      }
     ],
     "prompt_number": 33
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.calculateForces()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 34
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.Fx[0]"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 35,
       "text": [
        "array([ 0.        ,  2.40155998, -0.0150441 ,  0.        ,  0.        ,\n",
        "        0.        ,  0.        ,  0.        ,  0.        ])"
       ]
      }
     ],
     "prompt_number": 35
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.force"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 73,
       "text": [
        "array([[  2.38651587e+00,   0.00000000e+00,   0.00000000e+00],\n",
        "       [ -1.50441043e-02,   0.00000000e+00,   0.00000000e+00],\n",
        "       [ -1.04083409e-16,   0.00000000e+00,   0.00000000e+00],\n",
        "       [ -1.04083409e-16,   0.00000000e+00,   0.00000000e+00],\n",
        "       [ -1.04083409e-16,   0.00000000e+00,   0.00000000e+00],\n",
        "       [ -1.04083409e-16,   0.00000000e+00,   0.00000000e+00],\n",
        "       [ -1.04083409e-16,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  1.50441043e-02,   0.00000000e+00,   0.00000000e+00],\n",
        "       [ -2.38651587e+00,   0.00000000e+00,   0.00000000e+00]])"
       ]
      }
     ],
     "prompt_number": 73
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasAux.stepPosition(gasIni,dt)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 88
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "(0.1*gasAux.vec_v)**2"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 104,
       "text": [
        "array([[  3.98952589e-02,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  1.15115403e-02,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  5.37358964e-02,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  1.58150114e-06,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  8.68631383e-03,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  1.16667723e-02,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  1.58616905e-03,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  2.65112605e-04,   0.00000000e+00,   0.00000000e+00],\n",
        "       [  4.14368538e-07,   0.00000000e+00,   0.00000000e+00]])"
       ]
      }
     ],
     "prompt_number": 104
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "PhiSF(0.6,1,gasIni.eps,gasIni.rc, gasIni.PhiLJ_rc, gasIni.DrPhiLJOverr_rc)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 103,
       "text": [
        "6.727574981231751"
       ]
      }
     ],
     "prompt_number": 103
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasAux.calculateDeltas()\n",
      "gasAux.calculateForces()\n",
      "gasAux.force"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 92,
       "text": [
        "array([[ 2.42876711,  0.        ,  0.        ],\n",
        "       [ 0.10131319,  0.        ,  0.        ],\n",
        "       [-0.26166052,  0.        ,  0.        ],\n",
        "       [ 0.06044569,  0.        ,  0.        ],\n",
        "       [ 0.13576743,  0.        ,  0.        ],\n",
        "       [-0.15972747,  0.        ,  0.        ],\n",
        "       [ 0.0773761 ,  0.        ,  0.        ],\n",
        "       [ 0.01140432,  0.        ,  0.        ],\n",
        "       [-2.39368583,  0.        ,  0.        ]])"
       ]
      }
     ],
     "prompt_number": 92
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "gasIni.DrPhiLJOverr_rc"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 107,
       "text": [
        "0.0015599790981120005"
       ]
      }
     ],
     "prompt_number": 107
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "DrPhiLJOverr(2.5**2,1, 0.1)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 92,
       "text": [
        "0.0015599790981120005"
       ]
      }
     ],
     "prompt_number": 92
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "FSFAxis(2.5**2,-2.5,1.0,0.1,gasIni.DrPhiLJOverr_rc)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 91,
       "text": [
        "-0.0"
       ]
      }
     ],
     "prompt_number": 91
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "ejex**2"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 11,
       "text": [
        "array([ 0.81  ,  0.8281,  0.8464,  0.8649,  0.8836,  0.9025,  0.9216,\n",
        "        0.9409,  0.9604,  0.9801])"
       ]
      }
     ],
     "prompt_number": 11
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "ejex = np.arange(0.9,3,0.01)\n",
      "ejey = np.zeros(len(ejex))\n",
      "for i in range(len(ejex)):\n",
      " ejey[i] = PhiSF((ejex[i]**2), 1.0, 0.1, 2.5, gasIni.PhiLJ_rc, gasIni.DrPhiLJOverr_rc)\n",
      "#ejey = FSFAxis(ejex,-1.0,1.0,0.1,gasIni.DrPhiLJOverr_rc)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 26
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "plt.grid()\n",
      "plt.plot(ejex,ejey)\n",
      "plt.show()"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [],
     "prompt_number": 37
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "PhiSF(1.0, 1.0, 0.1, 2.5, gas_ini.PhiLJ_rc, gas_ini.DrPhiLJOverr_rc)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 42,
       "text": [
        "0.005726634246144001"
       ]
      }
     ],
     "prompt_number": 42
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "DrPhiLJOverr(1.0,1.0,0.1)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "metadata": {},
       "output_type": "pyout",
       "prompt_number": 40,
       "text": [
        "-2.4000000000000004"
       ]
      }
     ],
     "prompt_number": 40
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [],
     "language": "python",
     "metadata": {},
     "outputs": []
    }
   ],
   "metadata": {}
  }
 ]
}